$OpenBSD: patch-src_sigfile_c,v 1.2 2014/07/10 08:18:37 giovanni Exp $
--- src/sigfile.c.orig	Wed Dec 25 11:16:53 2013
+++ src/sigfile.c	Tue Jul  8 19:47:12 2014
@@ -162,8 +162,6 @@ static FILE *
 open_random_sig(
 	char *sigdir)
 {
-	srand((unsigned int) time(NULL));
-
 	if (chdir(sigdir) == 0) {
 		if (thrashdir(sigdir) || !*sigfile) {
 #ifdef DEBUG
@@ -236,7 +234,7 @@ thrashdir(
 			return 1;
 		}
 #endif /* HAVE_REWINDDIR */
-		pick = rand() % numentries + 1;
+		pick = arc4random_uniform(numentries) + 1;
 		while (--pick >= 0) {
 			if ((dp = readdir(dirp)) == NULL)
 				break;
